Set Environment Variables - Tomcat

  1. For Windows deployment we need to create setenv.bat file in the bin folder of extracted Tomcat directory.

  2. For Linux deployment we need to create setenv.sh file in the bin folder of extracted Tomcat directory.

  3. The following configuration needs to be placed in the setenv.bat file for Windows environment.

Windows Arguments

set CATALINA_OPTS=-Xms4096m -Xmx4096m -XX:+UseG1GC
-Dtangosol.coherence.cacheconfig="C:/Servers/Tomcat/SLInstance/shared/conf/service-coherence-cache-config.xml"
-Dtangosol.pof.config=com-adminserver-pas-web-pof-config.xml
-Dtangosol.coherence.override="C:/Servers/Tomcat/SLInstance/shared/conf/service-coherence-config.xml"
-Doracle.jdbc.fanEnabled=false -Djava.util.logging.config.file="C:/Servers/Tomcat/SLInstance/shared/conf/logging.properties"
-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl
-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl
-Dtangosol.coherence.distributed.localstorage=true -Dserver.name="<Name of the server>"
set OIPA_KEYSTORE_PWD=changeit

Note: Each argument should be separated by space and not the next line(Enter).

For Linux environment in setenv.sh

export CATALINA_OPTS="-Xms4096m -Xmx4096m -XX:+UseG1GC
-Dtangosol.coherence.cacheconfig=/Servers/Tomcat/SLInstance/shared/conf/service-coherence-cache-config.xml
-Dtangosol.pof.config=com-adminserver-pas-web-pof-config.xml
-Dtangosol.coherence.override=/Servers/Tomcat/SLInstance/shared/conf/service-coherence-config.xml
-Doracle.jdbc.fanEnabled=false -Djava.util.logging.config.file=/Servers/Tomcat/SLInstance/shared/conf/logging.properties
-Djavax.xml.parsers.DocumentBuilderFactory=com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl
-Djavax.xml.parsers.SAXParserFactory=com.sun.org.apache.xerces.internal.jaxp.SAXParserFactoryImpl
-Dtangosol.coherence.distributed.localstorage=true -Dserver.name=<Name of the server>"
export OIPA_KEYSTORE_PWD="changeit"

Note: To enable remote debugging Debug.

-agentlib:jdwp=transport=dt_socket,address=1044,server=y,suspend=n

To Enable JMX events to Admin console application

Add to existing class path

-Dcom.sun.management.jmxremote.ssl=false -Dcom.sun.management.jmxremote.authenticate=false -Dcom.sun.management.jmxremote.autodiscovery=true -Dcom.sun.management.jmxremote.port=<Unique Port Number>

If servers JMX port is not getting exposed to jconsole or adminconsole use below argument as well in that server arguments. ip address should be server actual ip address.

Rmi Port

Djava.rmi.server.hostname=ipaddress